<template>
  <div>
    第一个123
    <formRender :schema="state.schema" :formData="state.formData"></formRender>
  </div>
</template>
<script setup lang="ts">
import { reactive } from "vue";
const state = reactive({
  schema: {
    type: "object",
    title: "看下",
    properties: {
      AllString: {
        title: "string类",
        type: "AyiBoolean",
        default: "1@qq.com",
        validatorObj: {
          name: "isEmail1",
          options: "",
          other: "1@qq.com",
          msg: "提示信息",
        },
        "ui:hidden": (val: any, rootValue: object) => {
          // console.log("我是个方法", val, rootValue);
        },
      },
      // AllString2: {
      //   title: "string类",
      //   type: "AyiBoolean",
      //   default: "1@qq.com",
      //   validatorObj: {
      //     name: "isEmail1",
      //     options: "",
      //     other: "1@qq.com",
      //     msg: "提示信息",
      //   },
      //   "ui:hidden": "{{rootValue.AllString !== 'goal'}}",
      // },
    },
    required: ["AllString"],
  },
  formData: {
    content: "<a>超链接</a>",
  },
});
</script>
